<!DOCTYPE html>
<html>
<head>
	<meta charset="utf-8">
	<meta http-equiv="X-UA-Compatible" content="IE=edge">
	<title></title>
	<layuicss/>
	<style>
		.layui-input {

		}
	</style>
</head>
<body>
	
	<div style="margin: 15px;">
		<form class="layui-form">
			<input type="hidden" id="id" name="id" value="{$course.id|default=''}">
			<div class="layui-form-item">
				<label class="layui-form-label">学院：</label>
				<div class="layui-input-block" style="width: 240px;">
					<select name="college_id" id="" lay-filter="">
						<option value="">请选择学院</option>
						<volist name="college_list" id="cl">
							<option value="{$cl['id']}" <eq name="cl.id" value="$course.college_id">selected="selected"</eq>>{$cl.name}</option>
						</volist>
					</select>
				</div>
			</div>
			<div class="layui-form-item">
				<label class="layui-form-label">学科名称</label>
				<div class="layui-input-block" style="width:300px;">
					<input type="text" name="name" lay-verify="name" autocomplete="off" style="width: 80%;" placeholder="请输入学科名称" class="layui-input"  value="{$course.name|default=''}">
				</div>
			</div>
			<div class="layui-form-item">
				<label class="layui-form-label">备注</label>
				<div class="layui-input-block" style="width:300px;">
					<input type="text" name="remarks" lay-verify="remarks" style="width: 80%;" autocomplete="off" placeholder="请输入备注（可为空）" class="layui-input"  value="{$course.remarks|default=''}">
				</div>
			</div>
			<div class="layui-form-item">
				<div class="layui-input-block">
					<button class="layui-btn" lay-submit="" lay-filter="demo1">保存</button>
					<button type="reset" class="layui-btn layui-btn-primary">重置</button>
					<eq name="type" value="update">
						<a href="javascript:;" class="layui-btn layui-btn-danger del">删除</a>
					</eq>
				</div>
			</div>

		</form>
	</div>

	<layuijs/>
	<script type="text/javascript">
		var editurl = "";
		if ('{$type}' == 'update'){
			editurl = "{:U('Home/CourseMgr/updateCourse')}";
		}else if ('{$type}' == 'add'){
			editurl = "{:U('Home/CourseMgr/addCourse')}";
		}
		var rooturl = "__ROOT__/";
		var deleteurl = "{:U('Home/CourseMgr/deleteCourse')}"
	</script>
	<script type="text/javascript" src="__PUBLIC__/static/js/editCourse.js"></script>

</body>
</html>